package com.cw.DesignModel23.Ceational.BuilderPattern.builder1;

/**
 * 建造者实现类
 */
public class StudentBuilderImpl extends StudentBuilder {

    private Student student = new Student();

    @Override
    public void buildName(String name) {
        this.student.setName(name);
    }

    @Override
    public void buildAge(String age) {
        this.student.setAge(age);
    }

    @Override
    public void buildNumber(String number) {
        this.student.setNumber(number);
    }

    @Override
    public void buildAddress(String address) {
        this.student.setAddress(address);
    }

    @Override
    public void buildSchool(String school) {
        this.student.setSchool(school);
    }

    @Override
    public Student makeCourse() {
        return this.student;
    }
}
